Page({
  onLoad() {
    getApp().checkLogin()

    this.getList()
  },

  // 获取列表
  async getList() {
    let { data } = await wx.http({
      url: '/repair'
    })
    this.setData({
      list: data.rows
    })
  },

  // 去详情页
  goDetail(e) {
    wx.navigateTo({
      url: '/repair_pkg/pages/detail/index?id=' + e.mark.id,
    })
  },


  // 新增报修
  addRepair() {
    wx.navigateTo({
      url: '/repair_pkg/pages/form/index',
    })
  },
})
